var connector = require("../../../src/runtime/jaba");

var index = 0;

(function($service$){
var $input$ = {};

/* Init code */

/* Remote code */
var $script$ = 'for customer in root.Customers do (for order in customer.Orders do (g0:order.OrderID) end; ) end; ';
var $batch$ = $service$.execute($script$, $input$, function($result$) {

/* Local code */
$result$.getIteration("customer").forEach(function(customer){
index++ ;
customer.getIteration("order").forEach(function(order){
console.log(((("Customer #" + index) + " has an order with OrderID ") + order.getString("g0")));
});
});

});
})(connector);